/* 我的简历页面样式 */

/* 仪表盘布局 */
.dashboard-container {
    display: flex;
    min-height: calc(100vh - 70px);
}

/* 侧边栏 */
.dashboard-sidebar {
    width: 260px;
    background-color: #fff;
    border-right: 1px solid var(--color-gray-200);
    display: flex;
    flex-direction: column;
}

.user-info {
    padding: 24px 20px;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.user-details {
    flex: 1;
}

.user-name {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 4px 0;
    color: var(--color-gray-900);
}

.user-membership {
    display: flex;
    align-items: center;
    gap: 8px;
}

.badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.badge-premium {
    background-color: var(--color-gold-light);
    color: var(--color-gold);
}

.membership-expires {
    font-size: 12px;
    color: var(--color-gray-600);
}

.dashboard-nav {
    flex: 1;
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--color-gray-700);
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-item:hover {
    background-color: var(--color-gray-50);
    color: var(--color-gray-900);
}

.nav-item.active {
    background-color: var(--color-primary-light);
    color: var(--color-primary);
    font-weight: 500;
}

.nav-item img {
    width: 20px;
    height: 20px;
    opacity: 0.7;
}

.nav-item.active img {
    opacity: 1;
}

.sidebar-footer {
    padding: 20px 0;
    border-top: 1px solid var(--color-gray-200);
}

.logout-link {
    color: var(--color-danger) !important;
}

.logout-link:hover {
    background-color: var(--color-danger-light) !important;
}

/* 主内容区 */
.dashboard-content {
    flex: 1;
    padding: 24px;
    background-color: var(--color-gray-50);
    overflow-y: auto;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.content-header h1 {
    font-size: 24px;
    font-weight: 600;
    margin: 0;
    color: var(--color-gray-900);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-box {
    position: relative;
}

.search-box input {
    width: 240px;
    padding: 8px 12px 8px 36px;
    border: 1px solid var(--color-gray-200);
    border-radius: 4px;
    font-size: 14px;
    background-color: #fff;
}

.search-box input:focus {
    border-color: var(--color-primary);
    outline: none;
}

.search-btn {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

.search-btn img {
    width: 16px;
    height: 16px;
    opacity: 0.5;
}

/* 筛选器 */
.content-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 16px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.filter-group label {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-gray-700);
}

.filter-buttons {
    display: flex;
    gap: 8px;
}

.filter-btn {
    padding: 6px 12px;
    border: 1px solid var(--color-gray-200);
    border-radius: 4px;
    background-color: #fff;
    font-size: 14px;
    color: var(--color-gray-700);
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-btn:hover {
    border-color: var(--color-gray-400);
}

.filter-btn.active {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

/* 简历网格 */
.resumes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.resume-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.resume-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.resume-preview {
    position: relative;
    height: 200px;
    overflow: hidden;
    background-color: var(--color-gray-100);
}

.resume-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.resume-card:hover .resume-preview img {
    transform: scale(1.05);
}

.resume-actions {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    opacity: 0;
    transition: all 0.2s ease;
}

.resume-card:hover .resume-actions {
    opacity: 1;
}

.action-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-btn:hover {
    background-color: var(--color-primary);
}

.action-btn:hover img {
    filter: brightness(0) invert(1);
}

.action-btn img {
    width: 16px;
    height: 16px;
}

.resume-info {
    padding: 16px;
}

.resume-title {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: var(--color-gray-900);
}

.resume-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.resume-date {
    font-size: 13px;
    color: var(--color-gray-600);
}

.resume-status {
    font-size: 12px;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: 4px;
}

.resume-status.complete {
    background-color: var(--color-success-light);
    color: var(--color-success);
}

.resume-status.draft {
    background-color: var(--color-warning-light);
    color: var(--color-warning);
}

.resume-stats {
    display: flex;
    gap: 16px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--color-gray-600);
}

.stat-item img {
    width: 14px;
    height: 14px;
    opacity: 0.7;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.pagination-btn {
    width: 36px;
    height: 36px;
    border-radius: 4px;
    border: 1px solid var(--color-gray-200);
    background-color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--color-gray-700);
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination-btn:hover:not(:disabled) {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.pagination-btn.active {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-btn img {
    width: 16px;
    height: 16px;
}

.pagination-ellipsis {
    width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--color-gray-600);
}

/* 模态框 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    width: 100%;
    max-width: 600px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.modal.active .modal-content {
    transform: translateY(0);
}

.modal-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    color: var(--color-gray-900);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--color-gray-500);
    cursor: pointer;
}

.modal-body {
    padding: 24px;
    max-height: 70vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--color-gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* 模板选择 */
.template-selection {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 12px;
}

.template-option {
    position: relative;
    border: 2px solid var(--color-gray-200);
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
}

.template-option:hover {
    border-color: var(--color-gray-400);
}

.template-option.active {
    border-color: var(--color-primary);
}

.template-option img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.template-name {
    display: block;
    padding: 8px;
    font-size: 13px;
    text-align: center;
    background-color: var(--color-gray-50);
}

.template-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 2px 6px;
    background-color: var(--color-gold);
    color: #fff;
    font-size: 11px;
    font-weight: 500;
    border-radius: 4px;
}

/* 开始选项 */
.start-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 12px;
}

.start-option {
    position: relative;
}

.start-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.start-option label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
    border: 2px solid var(--color-gray-200);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.start-option label:hover {
    border-color: var(--color-gray-400);
}

.start-option input[type="radio"]:checked + label {
    border-color: var(--color-primary);
    background-color: var(--color-primary-light);
}

.start-option label img {
    width: 32px;
    height: 32px;
    opacity: 0.7;
}

.start-option input[type="radio"]:checked + label img {
    opacity: 1;
}

.option-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 2px 6px;
    background-color: var(--color-gold);
    color: #fff;
    font-size: 11px;
    font-weight: 500;
    border-radius: 4px;
}

/* 响应式调整 */
@media (max-width: 992px) {
    .dashboard-container {
        flex-direction: column;
    }
    
    .dashboard-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--color-gray-200);
    }
    
    .user-info {
        padding: 16px;
    }
    
    .dashboard-nav, .sidebar-footer {
        padding: 8px 0;
    }
    
    .nav-item {
        padding: 10px 16px;
    }
    
    .template-selection, .start-options {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .content-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .header-actions {
        width: 100%;
        flex-direction: column;
        gap: 12px;
    }
    
    .search-box, .search-box input {
        width: 100%;
    }
    
    .content-filters {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .resumes-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .template-selection, .start-options {
        grid-template-columns: 1fr;
    }
}